﻿@page
@model Rosd.Pages.Incomes.IndexModel

@{
    ViewData["Title"] = "Index";
}

<h1>Index</h1>

<p>
    <a asp-page="Create">Create New</a>
</p>
<table class="table">
    <thead>
        <tr>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].IncDate)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].IncNum)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].IncPerson)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].Way)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].Date)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].Num)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].DocFrom)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].DocDate)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].DocNum)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].Subject)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].AttnTo)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].Person)
            </th>
            <th>
                @Html.DisplayNameFor(model => model.Income[0].Note)
            </th>
            <th></th>
        </tr>
    </thead>
    <tbody>
@foreach (var item in Model.Income) {
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item.IncDate)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.IncNum)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.IncPerson)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Way)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Date)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Num)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.DocFrom)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.DocDate)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.DocNum)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Subject)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.AttnTo)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Person)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Note)
            </td>
            <td>
                <a asp-page="./Edit" asp-route-id="@item.Id">Edit</a> |
                <a asp-page="./Details" asp-route-id="@item.Id">Details</a> |
                <a asp-page="./Delete" asp-route-id="@item.Id">Delete</a>
            </td>
        </tr>
}
    </tbody>
</table>
